home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1995…tember: Reference Library / Dev.CD Sep 95 RL / Dev.CD Sep 95 RL.toast / mac / Technical Documentation / develop / develop Issue 15 code / Floating Windows / Infinity Windoid WDEF 3.0 / Source Code / Makefile < prev    next >
Encoding:
Makefile  |  1995-02-20  |  6.1 KB  |  187 lines  |  [TEXT/MPS ]

  1. # ==============================================================================
  2. #
  3. #    Infinity Windoid 3.0
  4. #
  5. #                makefile for MPW
  6. #
  7. # ------------------------------------------------------------------------------
  8. #              © 1991-95 Troy Gaul
  9. #                and Infinity Systems
  10. #                All Rights Reserved.
  11. # ------------------------------------------------------------------------------
  12. #   File:        Makefile
  13. #   Targets:    Infinity Windoid 3.0
  14. #                  Infinity Windoid/PPC
  15. #   Sources:    InfinityWindoid.c
  16. #               WindoidUtil.c
  17. #               WindoidDraw.c
  18. # ==============================================================================
  19.  
  20. Output        =    Infinity Windoid 3.0
  21. PPCOut        =    Infinity Windoid/Fat
  22.  
  23. OutRsrc        =    InfinityWDEF.rsrc            # intermediate file for Fat build
  24.  
  25.  
  26. # ==============================================================================
  27. #    Types and IDs
  28. # ------------------------------------------------------------------------------
  29. Type        =    rsrc
  30. Creator        =    RSED
  31. ResType        =    WDEF
  32. ResID        =    128
  33.  
  34.  
  35. # ==============================================================================
  36. #    Directories
  37. # ------------------------------------------------------------------------------
  38. ObjDir        =    :obj:
  39.  
  40. {ObjDir}    ƒ    :                # directory dependency
  41.  
  42.  
  43. # ==============================================================================
  44. #    68K Options/Libs
  45. # ------------------------------------------------------------------------------
  46. 68KC        =    C                # Can be changed to use a different MPW-hosted
  47.                                 # compiler.
  48.  
  49. 68KCOptions    =   -w                # no warnings                                 ∂
  50.                 -b                # PC-relative strings                        ∂
  51.                 -mbg off         # off, full                                    ∂
  52.                 -opt full        # off, (empty)=normal, full, size, speed    ∂
  53.                 -o "{ObjDir}"
  54.  
  55.  
  56. # ==============================================================================
  57. #    PowerPC Options/Libs
  58. # ------------------------------------------------------------------------------
  59. PPCC        =    PPCC            # Can be changed to use a different MPW-hosted
  60.                                 # PowerPC compiler.
  61.  
  62. PPCCOptions    =    -w conformance -appleext on
  63.  
  64. PPCPefLibs    =    -l InterfaceLib.xcoff=InterfaceLib                            ∂
  65.                 -l StdCLib.xcoff=StdCLib                                    ∂
  66.                 -l MathLib.xcoff=MathLib
  67.  
  68. PPCLinkLibs    =    "{PPCLibraries}"InterfaceLib.xcoff                             ∂
  69.                 "{PPCLibraries}"StdCLib.xcoff                                 ∂
  70.                 "{PPCLibraries}"StdCRuntime.o                                 ∂
  71.                 "{PPCLibraries}"PPCCRuntime.o
  72.  
  73.  
  74. # ==============================================================================
  75. #    Object Files
  76. # ------------------------------------------------------------------------------
  77. 68KObjects    =    "{ObjDir}"InfinityWindoid.c.o                                ∂
  78.                 "{ObjDir}"WindoidUtil.c.o                                    ∂
  79.                 "{ObjDir}"WindoidDraw.c.o
  80.  
  81. PPCObjects    =    "{ObjDir}"InfinityWindoid.o                                    ∂
  82.                 "{ObjDir}"WindoidUtil.o                                        ∂
  83.                 "{ObjDir}"WindoidDraw.o
  84.                 
  85.  
  86. # ==============================================================================
  87. #    Headers
  88. # ------------------------------------------------------------------------------
  89. AllHeaders    =     WindoidDefines.h                                            ∂
  90.                 WindoidTypes.h                                                ∂
  91.                 WindoidUtil.h                                                ∂
  92.                 WindoidDraw.h
  93.  
  94.  
  95. # ==============================================================================
  96. #    68K Compilation
  97. # ------------------------------------------------------------------------------
  98. "{ObjDir}"InfinityWindoid.c.o    ƒ    Makefile                                 ∂
  99.                                     InfinityWindoid.c                        ∂
  100.                                     {AllHeaders}
  101.     {68KC} {68KCOptions} InfinityWindoid.c
  102.  
  103. # ------------------------------------------------------------------------------
  104. "{ObjDir}"WindoidUtil.c.o        ƒ    Makefile                                 ∂
  105.                                     WindoidUtil.c                            ∂
  106.                                     {AllHeaders}
  107.     {68KC} {68KCOptions} WindoidUtil.c
  108.  
  109.  
  110. # ------------------------------------------------------------------------------
  111. "{ObjDir}"WindoidDraw.c.o        ƒ    Makefile                                 ∂
  112.                                     WindoidDraw.c                            ∂
  113.                                     {AllHeaders}
  114.     {68KC} {68KCOptions} WindoidDraw.c
  115.  
  116.  
  117. # ==============================================================================
  118. #    PowerPC Compilation
  119. # ------------------------------------------------------------------------------
  120. "{ObjDir}"InfinityWindoid.o        ƒ    Makefile                                 ∂
  121.                                     InfinityWindoid.c                        ∂
  122.                                     {AllHeaders}
  123.     {PPCC} {PPCCOptions} InfinityWindoid.c    -o "{ObjDir}"InfinityWindoid.o
  124.  
  125.  
  126. # ------------------------------------------------------------------------------
  127. "{ObjDir}"WindoidUtil.o            ƒ    Makefile                                 ∂
  128.                                     WindoidUtil.c                            ∂
  129.                                     {AllHeaders}
  130.     {PPCC} {PPCCOptions} WindoidUtil.c        -o "{ObjDir}"WindoidUtil.o
  131.  
  132.  
  133. # ------------------------------------------------------------------------------
  134. "{ObjDir}"WindoidDraw.o            ƒ    Makefile                                 ∂
  135.                                     WindoidDraw.c                            ∂
  136.                                     {AllHeaders}
  137.     {PPCC} {PPCCOptions} WindoidDraw.c        -o "{ObjDir}"WindoidDraw.o
  138.  
  139.  
  140. # ==============================================================================
  141. #    Linking
  142. # ------------------------------------------------------------------------------
  143. 68KLinkOpts    =    -m MAIN                                                        ∂
  144.                 -ra "{Output}"=0                                            ∂
  145.                 -sg "{Output}"
  146.  
  147.  
  148. # ------------------------------------------------------------------------------
  149. #    68K version
  150.  
  151. "{Output}"    ƒƒ    Makefile {68KObjects}
  152.     Link        -t {Type} -c {Creator} -rt {ResType}={ResID}                 ∂
  153.                 {68KObjects} {68KLinkOpts}                                    ∂
  154.                 -o {Targ}
  155.  
  156.  
  157. # ------------------------------------------------------------------------------
  158. #    Fat version - 68K
  159.  
  160. "{OutRsrc}"    ƒƒ    Makefile {68KObjects}
  161.     Link        -t rsrc -c RSED -rt oCod={ResID}                            ∂
  162.                 {68KObjects} {68KLinkOpts}                                     ∂
  163.                 -o {Targ}
  164.  
  165.  
  166. # ------------------------------------------------------------------------------
  167. #    Fat version - PowerPC
  168.  
  169. "{OutRsrc}"    ƒƒ    Makefile {PPCObjects}
  170.     PPCLink -warn -main main                                                 ∂
  171.             {PPCObjects} {PPCLinkLibs}                                        ∂
  172.             -o "{ObjDir}"InfinityWDEF.xcoff
  173.     makepef -b "{ObjDir}"InfinityWDEF.xcoff -o InfinityWDEF.pef {PPCPefLibs}
  174.     echo "read ∂'pCod∂' (128) ∂"InfinityWDEF.pef∂";" | rez -a -o "{OutRsrc}"
  175.  
  176.  
  177. # ------------------------------------------------------------------------------
  178. #    Put the versions together in a fat binary WDEF
  179.  
  180. "{PPCOut}"    ƒ    Makefile {OutRsrc}
  181.     rez InfinityWDEF.r -a -o {Targ}
  182.     setfile -t {Type} -c {Creator} {Targ}
  183. #    Delete "{OutRsrc}"        # you might want to delete the intermediate file
  184.  
  185.  
  186. # ------------------------------------------------------------------------------
  187.